package org.example.application.assembler;

import org.example.domain.model.Order;
import org.example.interfaces.dto.OrderDTO;
import org.springframework.beans.BeanUtils;

/**
 * @author liyishan
 * @date 2023/5/10 14:47
 * @apiNote
 */

public class OrderDtoAssembler {

    public static OrderDTO orderToDTO(Order order){
        OrderDTO orderDTO = new OrderDTO();
        BeanUtils.copyProperties(order, orderDTO);
        return orderDTO;
    }

}
